package org.binglan.youziyuepai.service;

import org.binglan.youziyuepai.entity.PersonalDynamicApply;
import com.baomidou.mybatisplus.extension.service.IService;
import org.binglan.youziyuepai.enums.code.StatusEnum;

import java.util.List;

/**
 * <p>
 * 约拍申请表 服务类
 * </p>
 *
 * @author sanjin
 * @since 2019-04-24
 */
public interface PersonalDynamicApplyService extends IService<PersonalDynamicApply> {

    PersonalDynamicApply savePersonalDynamicApply(PersonalDynamicApply personalDynamicApply);

    /**
     * 查询用户收到的约拍请求
     * @param userId
     * @return
     */
    List<PersonalDynamicApply> queryReceivePersonalDynamicApplyByUserId(String userId);

    /**
     * 查询用户发送的约拍请求
     * @param userId
     * @return
     */
    List<PersonalDynamicApply> querySendPersonalDynamicApplyByUserId(String userId);


    /**
     * 改变约拍请求的状态
     * @param userId
     * @param applyId
     * @param statusEnum
     * @return
     */
    PersonalDynamicApply changeDatePatApplyStatus(String userId, Integer applyId, StatusEnum statusEnum);


}
